package com.zenithmind.library.pojo.dto;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.Size;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDate;

/**
 * 图书副本更新DTO
 * 
 * @author ZenithMind
 * @since 2024-06-14
 */
@Data
@Schema(name = "图书副本更新DTO", description = "更新图书副本时的数据传输对象")
public class BookCopyUpdateDTO {

    @Size(max = 50, message = "条形码长度不能超过50个字符")
    @Schema(description = "条形码", example = "BC001")
    private String barcode;

    @Size(max = 50, message = "RFID标签长度不能超过50个字符")
    @Schema(description = "RFID标签", example = "RFID001")
    private String rfidTag;

    @Schema(description = "状态 (0-不可借阅, 1-可借阅, 2-已借出, 3-维修中, 4-丢失, 5-损坏)", example = "1")
    private Integer status;

    @Size(max = 200, message = "位置信息长度不能超过200个字符")
    @Schema(description = "位置信息", example = "A区1层1号书架")
    private String location;

    @Size(max = 20, message = "书架号长度不能超过20个字符")
    @Schema(description = "书架号", example = "A-1-1")
    private String shelfNumber;

    @Schema(description = "层号", example = "1")
    private Integer floorNumber;

    @Size(max = 50, message = "区域长度不能超过50个字符")
    @Schema(description = "区域", example = "A区")
    private String area;

    @Schema(description = "采购价格", example = "29.80")
    private BigDecimal purchasePrice;

    @Schema(description = "采购日期", example = "2024-01-01")
    private LocalDate purchaseDate;

    @Size(max = 100, message = "供应商长度不能超过100个字符")
    @Schema(description = "供应商", example = "新华书店")
    private String supplier;

    @Size(max = 500, message = "备注长度不能超过500个字符")
    @Schema(description = "备注", example = "更新位置信息")
    private String remarks;
}
